home *** CD-ROM | disk | FTP | other *** search
/ Turnbull China Bikeride / Turnbull China Bikeride - Disc 1.iso / ARGONET / PD / EMULATOR / D64IMAGE.ZIP / !D64FS / !Help < prev    next >
Text File  |  1997-03-21  |  7KB  |  174 lines

  1. D64FS - An Image Filing System for C64 disc images (V0.00)
  2. ==========================================================
  3.  
  4.  
  5.  
  6. Now with a native RISC OS C64-Emulator available there's the question
  7. of how to get software for the emulator. The most common source data
  8. are files in T64 and D64 format. The former are tape archive files
  9. with a very simple structure, used mainly for programs that don't
  10. load any additional files after startup. The later are byte-for-byte
  11. copies of VC1541 disc images used mostly for programs that do load
  12. additional files. In contrast to T64 archives extracting files from
  13. a D64 disc image is considerably more complicated than 10 seconds
  14. worth of editing. Therefore I chose to write this image filing system
  15. which does the job for you and also shows why a modular OS is a
  16. really good idea.
  17.  
  18. All you have to do is start the module (type "help d64fs" at the
  19. command line to see if it's active) and give the disc images the
  20. file type &164 (D64Image). This filetype, the module name and its star
  21. commands are all registered at Acorn, therefore this release is
  22. official.
  23. That done you merely have to double-click on the image to open a
  24. filer window with its contents. Accessing files is considerably
  25. slower than with native RISC OS files. One reason for this is that
  26. the data blocks contained in a file can be spread over a large area of
  27. the image file. The other one is that C64 disc images don't give the
  28. _exact_ size of a file with its directory entry (only the number of
  29. blocks which doesn't even have to be correct). RISC OS has to know
  30. the exact size of a file _before_ loading, however, so when loading
  31. a file it has to be scanned first; that means the file will have to
  32. be traversed twice, hence the delay.
  33. Of course I might have claimed lots of RMA space for buffering but I
  34. decided against this on the grounds that D64FS is not supposed to be
  35. a high performance FS for everyday use but a convenient and RISC OS
  36. compliant way of accessing this type of data. If you're doing lots
  37. of operations on a disc image you can always speed things up a lot
  38. by copying it into a RAM disc.
  39.  
  40. D64FS is read _and write_ so you can also copy stuff into disc images
  41. or create new ones. The disc image size is not fixed to the standard
  42. 35 tracks but may be any value between 18 and 40. If the number of
  43. tracks exceeds 35 the format used for the BAM will be that of Dolphin
  44. DOS (that means essentially that the BAM entries for tracks 36-40
  45. start in Block 18,0 at offset &ac).
  46.  
  47. Discs aren't recognized if the image is less than 18 "tracks" long
  48. (no directory track) or the first two bytes in block 18,0 are not 18,1.
  49. I used to check for the full 18,1,65,0 as given in the VC1541 manual
  50. but discarded that again when I came across disc images that didn't
  51. conform with this.
  52.  
  53.  
  54. Name conversions:
  55. -----------------
  56.  
  57. This is a bit tricky since the character sets used by RISC OS and by
  58. the C64 are rather different. You shouldn't experience any trouble if
  59. you stick to non-accented (top bit clear) characters (with the exception
  60. of char #152 and char #156 which are OK), best to keep them lower case as
  61. well. Some CBM-characters are translated to the same RISC OS characters,
  62. however, so there might be name clashes (for instance `.' and <arrow left>
  63. are both translated to `_'). So far I haven't experienced any trouble but
  64. be warned that there may be.
  65.  
  66.  
  67. Filetype conversions:
  68. ---------------------
  69.  
  70. This is even trickier. The C64 knows 5 different filetypes, namely DEL,
  71. SEQ, PRG, USR and REL. I don't think using up 5 RISC OS filetypes just
  72. for this is a good idea and besides hardly anything but PRG is used
  73. anyway (with the exception of DEL which is only used on empty files,
  74. though). So I chose the following mappings:
  75.  
  76. DEL <--> &ffe    Command
  77. SEQ <--> &ffd    Data
  78. PRG <--> &064    (the filetype used by !Breadbox)
  79. USR <--> &ffc    Utility
  80. REL <--> &fff    Text
  81.  
  82. If you copy a RISC OS file with a different filetype into a disc image
  83. its type will default to PRG (&064).
  84.  
  85.  
  86.  
  87. Command Line options:
  88. =====================
  89.  
  90. D64FS offers two commands:
  91.  
  92. D64create [-t x] <filename> <discname,id>
  93.     This command creates a disc image file named <filename> with
  94.     x tracks (x between 18 and 40, default 35). The disc name (up
  95.     to 18 chars) and id (2 chars) are stored in the image; everyone
  96.     who ever worked with a C64 will know what they are.
  97.  
  98. D64tidy [-v -r -c] <filename>
  99.     This does various operations on a C64 image file. Be warned
  100.     that these operations might take some time (very much dependent
  101.     on what kind of device the image is stored on - this should be
  102.     a harddisc or a RAM disc). The aim of these operations is mostly
  103.     to discard any unused space and thus make the image file compress
  104.     better. Be warned that if the disc contains information not stored
  105.     in files this data will be lost irretrievably (-c,-r) or exposed
  106.     to overwriting (-v). Neither problem can arise with images created
  107.     by D64FS. When in doubt don't tidy up the disc!
  108.  
  109.     -v    Validate disc. That means update the BAM (block allocation
  110.         map), i.e. scan all files to determine which blocks are
  111.         used and which are not and write the result on the image.
  112.         This operation may be used if the BAM has been corrupted
  113.         for some reason. If the disc image contains data not stored
  114.         in files a following write-operation might overwrite it!
  115.  
  116.     -r    Clear unused rest of partially filled blocks. The last
  117.         block of a file is usually not filled to the end. The data
  118.         contained in the rest of the block has no purpose whatsoever
  119.         if the disc image contains only files and thus may be deleted
  120.         (i.e. overwritten with 0s).
  121.  
  122.     -c    Clear unused blocks. The most dangerous operation which will
  123.         fill entire blocks with 0s if they're marked unused in the
  124.         BAM. If the disc image contains data not stored in files
  125.         or a corrupt BAM data will be lost permanently so handle
  126.         with care!
  127.  
  128.     If you specify more than one switch the operations will be executed
  129.     in the following order: first -v and/or -r in parallel, then -c.
  130.     E.g. -v -c will first update the BAM and then clear unused blocks.
  131.  
  132.  
  133.  
  134.  
  135. LIMITATIONS:
  136. ------------
  137.  
  138. To keep down the workspace size the maximum number of open D64Image files is
  139. currently set to 32. If the module complains about there being too many open
  140. images you'll have to close some of them, for instance by typing *close at
  141. the CLI (which closes all open files on the current FS).
  142. The number of open files within D64 images is limited to 32 as well. This
  143. should usually not be a problem, though, since there's hardly ever more than
  144. one open (unless some program messed up).
  145.  
  146.  
  147.  
  148. KNOWN BUGS:
  149. -----------
  150.  
  151. 1) Files with zero length will take up one data block nonetheless. But that's
  152.    not really a bug since files like these are pretty senseless anyway.
  153.  
  154. 2) None I found so far (...and are still present...)
  155.  
  156.  
  157.  
  158.  
  159.  
  160. LEGAL ISSUES and CONTACT:
  161. =========================
  162.  
  163. This program is Videoware. For an explanation of what that means and how to
  164. contact me read the file "VIDEOWARE".
  165.  
  166.  
  167.  
  168.  
  169. Happy nostalgia,
  170.  
  171.  
  172.  
  173. Andreas Dehmel, March 97.
  174.